<%-- 
    Document   : review
    Created on : May 4, 2011, 4:40:28 PM
    Author     : alexnewski
--%>

<%@page import="java.util.Iterator"%>
<%@page import="com.movie.Viewer"%>
<%@page import="com.movie.Movie"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>

<%@include file="header.html"%>

<%
    Movie movie = (Movie) session.getAttribute("movie");
    Viewer viewer = (Viewer) session.getAttribute("user");
    
%>


<div>         
    <form method="POST" action="dispatcher?operation=recommend" >               
        <h3>Friends:</h3>
        <%
            Iterator iterator = viewer.ListOfFriendsAccepted().iterator();
            while (iterator.hasNext()) {
                Viewer friend = (Viewer) iterator.next();
                out.println("<input TYPE ='checkbox' name='friends' VALUE ='" + friend.getIdviewer() + "' > " + friend.getFirstname() + " " + friend.getLastname() + " <BR>");
            }

        %>
        <br>
        <p><input type="submit" class="button"/></p>
</div>
</form>

<%@include file="footer.html"%>